﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using DotNetEngine.Core;
using DotNetEngine.Utils;
using DotNetEngine.GUI;
using Microsoft.Xna.Framework;
using DotNetEngine.Graphics;

namespace DotNetEngine.Screens
{
    class OptionsMenuScreen: Screen
    {
        #region Properties
        DrawableImage menuBack;
        DrawableImage scroll;
        MenuControl mOptions;
        #endregion

        #region Initialize methods
        public override void Initialize()
        {
            base.Back = new DrawableImage(Directories.MenuDirectory + "BlueBackground", new Vector2(0, 0), 0);
            scroll = new DrawableImage(Directories.MenuDirectory + "CloudBackground", new Vector2(0, 0), 1);
            menuBack = new DrawableImage(Directories.MenuDirectory + "MenuCloudBack", new Vector2(650, 0), 2);
            mOptions = new MenuControl(new Vector2(300, 150), 3);
            MenuItem Option1 = new MenuItem("Option 1", delegate { }, 3);
            MenuItem Option2 = new MenuItem("Option 2", delegate { }, 3);
            MenuItem Back = new MenuItem("Back", delegate { BackScreen(); }, 3);
            mOptions.AddMenuItem(Option1);
            mOptions.AddMenuItem(Option2);
            mOptions.AddMenuItem(Back);


        }
        public override void OnInitialize()
        {
            base.OnInitialize();
        }
        #endregion

        #region Public methods
        public override void Update()
        {
            mOptions.Update();
        }
        public override void Draw()
        {
            base.Draw();
            mOptions.Draw();
            BaseGame.RenderElements.Add(scroll);
            BaseGame.RenderElements.Add(menuBack);
        }
        public void BackScreen()
        {
            BaseGame.RemoveScreen();
        }
        #endregion

    }
}
